{extend name="public/base" /}
{block name='content'}
{include file='public/content_header' /}
<!--数据列表页面-->
<section class="content">

    <!--顶部搜索筛选-->
    <div class="row">
        <div class="col-md-12">
            <div class="box">
                <div class="box-body">
                    <form class="form-inline searchForm" id="searchForm" action="{:url('index')}" method="GET">

                        <div class="form-group" style="padding-top: 3px;">
                            <input value="{$j_member_id ? $j_member_id : '' ;}"
                                   name="j_member_id" id="j_member_id" class="form-control input-sm"
                                   placeholder="举报者融云ID搜索">
                        </div>
                        <div class="form-group" style="padding-top: 3px;">
                            <input value="{$j_me_uid ? $j_me_uid : '' ;}"
                                   name="j_me_uid" id="j_me_uid" class="form-control input-sm"
                                   placeholder="举报者用户UID/昵称搜索">
                        </div>
                        <div class="form-group" style="padding-top: 3px;">
                            <input value="{$short_content ? $short_content : '' ;}"
                                   name="short_content" id="short_content" class="form-control input-sm"
                                   placeholder="短视频描述搜索">
                        </div>
                        <div class="form-group">
                            <select name="complain_id" id="complain_id" class="form-control input-sm">
                                <option value="">-投诉类型-</option>
                                {foreach name='complain_list' id='item'}
                                <option value="{$item.complain_id}" {if isset($complain_id)&& $complain_id==$item.complain_id}selected{/if}>{$item.complain_name}</option>
                                {/foreach}
                            </select>
                        </div>
                        <div class="form-group" style="padding-top: 3px;">
                            <select name="is_real" id="is_real" class="form-control input-sm index-search">
                                <option value="">-处理状态-</option>
                                <option value="0"{if isset($is_real) && $is_real=='0'}selected{/if}>未处理</option>
                                <option value="1"{if isset($is_real) && $is_real=='1'}selected{/if}>已处理（有效举报）</option>
                                <option value="2"{if isset($is_real) && $is_real=='2'}selected{/if}>已处理（无效举报）</option>
                            </select>
                        </div>
                        <div class="form-group" style="padding-top: 3px;">
                            <input value="{$f_member_id ? $f_member_id : '' ;}"
                                   name="f_member_id" id="f_member_id" class="form-control input-sm"
                                   placeholder="发布者融云ID搜索">
                        </div>
                        <div class="form-group" style="padding-top: 3px;">
                            <input value="{$f_me_uid ? $f_me_uid : '' ;}"
                                   name="f_me_uid" id="f_me_uid" class="form-control input-sm"
                                   placeholder="发布者用户UID/昵称搜索">
                        </div>
                        <div class="form-group" style="padding-top: 3px;">
                            <input value="{$add_time|default=''}" readonly name="add_time" id="add_time"
                                   class="form-control input-sm indexSearchDateRange" placeholder="举报时间搜索">
                        </div>
                        <script>
                            laydate.render({
                                elem: '#add_time',
                                range: true,
                            });
                        </script>

                        <div class="form-group" style="padding-top: 3px;">
                            <button class="btn btn-sm btn-primary" type="submit"><i class="fa fa-search"></i> 查询
                            </button>
                        </div>

                        <div class="form-group" style="padding-top: 3px;">
                            <button onclick="clearSearchForm()" class="btn btn-sm btn-default" type="button"><i
                                    class="fa  fa-eraser"></i> 清空查询
                            </button>
                        </div>
                    </form>
                </div>
            </div>
        </div>
    </div>

    <div class="row">
        <div class="col-md-12">
            <div class="box">

                <!--数据列表顶部-->
                <div class="box-header">
                    <div>
                        <a class="btn btn-success btn-sm ReloadButton" data-toggle="tooltip" title="刷新">
                            <i class="fa fa-refresh"></i> 刷新
                        </a>
                    </div>
                </div>

                <div class="box-body table-responsive">
                    <table class="table table-hover table-bordered datatable" width="100%">
                        <thead>
                        <tr style="white-space: nowrap">
                            <th style="text-align: center;width: 10%">举报者</th>
                            <th style="text-align: center;width: 5%">被举报视频ID</th>
                            <th style="text-align: center;width: 5%">视频标签</th>
                            <th style="text-align: center;width: 10%">视频描述</th>
                            <th style="text-align: center;width: 5%">封面</th>
                            <th style="text-align: center;width: 5%">短视频</th>
                            <th style="text-align: center;width: 5%">作品详情</th>
                            <th style="text-align: center;width: 10%">发布者</th>
                            <th style="text-align: center;width: 5%">举报类型</th>
                            <th style="text-align: center;width: 5%">举报理由</th>
                            <th style="text-align: center;width: 5%">举报图片</th>
                            <th style="text-align: center;width: 5%">是否申诉</th>
                            <th style="text-align: center;width: 10%">处理状态</th>
                            <th style="text-align: center;width: 5%">处理时间</th>
                            <th style="text-align: center;width: 5%">处理理由</th>
                            <th style="text-align: center;width: 5%">操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        {foreach name='data' id='item' key='data_key'}
                        <tr>
                            <td style="text-align: center;vertical-align: middle;">【融云ID：{$item.member_id}】【UID：{$item.j_me_uid}】【昵称：{$item.j_me_nick_name}】</td>
                            <td style="text-align: center;vertical-align: middle;">{$item.short_video_id}</td>
                            <td style="text-align: center;vertical-align: middle;">{$item.video_label_name}</td>
                            <td style="text-align: center;vertical-align: middle;" title="{$item.short_content}">{$item.short_content_word}</td>
                            <td style="text-align: center;vertical-align: middle;" class="photo-list"><img class="dataListImg" src="{$item.cover_url}"></td>
                            <td style="text-align: center;vertical-align: middle;" class="">
                                <video width="130" height="70" controls>
                                    <source src="{$item.video_url}" type="video/mp4">
                                </video>
                            </td>
                            <td style="text-align: center;vertical-align: middle;" class="">
                                <a data-id="{$item.short_video_id}" data-url="/admin_sjfUH12p.php/favideo/getexposureinfo" data-confirm="2" data-type="2"
                                   class="btn btn-default btn-xs AjaxButton"  title="作品详情" data-toggle="tooltip">
                                    <span>查看</span>
                                </a>
                            </td>
                            <td style="text-align: center;vertical-align: middle;">【融云ID：{$item.short_member_id}】【UID：{$item.f_me_uid}】【昵称：{$item.f_me_nick_name}】</td>
                            <td style="text-align: center;vertical-align: middle;">{$item.complain_name}</td>
                            <td style="text-align: center;vertical-align: middle;">{$item.complain_content}</td>

                            {if $item.complain_img == ''}
                            <td style="text-align: center;vertical-align: middle;">{$item.complain_img_word}</td>
                            {/if}
                            {if $item.complain_img != ''}
                            <td style="text-align: center;vertical-align: middle;" class="photo-list">
                                {foreach name='item.complain_img_word' id='items'}
                                <img class="dataListImg" src="{$items}">
                                {/foreach}
                            </td>
                            {/if}

                            {if $item.su_id == ''}
                            <td style="text-align: center;vertical-align: middle;">{$item.su_id_word}</td>
                            {/if}
                            {if $item.su_id != ''}
                            <td style="text-align: center;vertical-align: middle;">{$item.su_id_word}
                                <a data-width="60%" data-height="50%" data-id="{$item.short_video_id}" data-url="getappeal" data-title='查看短视频发布者的申诉' data-confirm="2" data-type="2" class="btn btn-default btn-xs AjaxButton"  title="查看申诉" data-toggle="tooltip">
                                    <span>查看申诉</span>
                                </a>
                            </td>
                            {/if}

                            <td style="text-align: center;vertical-align: middle;">{$item.is_real_word}</td>
                            <td style="text-align: center;vertical-align: middle;">{$item.handle_time}</td>
                            <td style="text-align: center;vertical-align: middle;">{$item.handle_content}</td>
                            <td style="text-align: center;vertical-align: middle;">
                                {if $item.is_real==0}
                                <a data-width="50%" data-height="40%" data-title="有效举报" data-id="{$item.id}" data-url="effective" data-confirm="2" data-type="2"
                                   class="btn btn-success btn-xs AjaxButton"  title="判定为有效举报，此短视频作品将继续被【封禁】" data-toggle="tooltip">
                                    有效举报
                                </a>
                                <a data-width="50%" data-height="40%" data-title="无效举报" data-id="{$item.id}" data-url="invalid" data-confirm="2" data-type="2"
                                   class="btn btn-danger btn-xs AjaxButton"  title="判定为无效举报，此短视频作品将被【解除封禁】，恢复正常状态" data-toggle="tooltip">
                                    无效举报
                                </a>
                                {else/}
                                -
                                </a>
                                {/if}
                            </td>


                        </tr>
                        {/foreach}
                        </tbody>
                    </table>
                </div>

                <!-- 数据列表底部 -->
                <div class="box-footer">
                    {$page|raw}
                    <label class="control-label pull-right" style="margin-right: 10px; font-weight: 100;">
                        <small>共{$total}条记录</small>&nbsp;
                        <small>每页显示</small>
                        &nbsp;
                        <select class="input-sm" onchange="changePerPage(this)">
                            <option value="10" {if $admin.per_page==10}selected{/if}>10</option>
                            <option value="20" {if $admin.per_page==20}selected{/if}>20</option>
                            <option value="30" {if $admin.per_page==30}selected{/if}>30</option>
                            <option value="50" {if $admin.per_page==50}selected{/if}>50</option>
                            <option value="100" {if $admin.per_page==100}selected{/if}>100</option>
                        </select>
                        &nbsp;
                        <small>条记录</small>
                    </label>
                </div>

            </div>
        </div>
    </div>
</section>
<script>
    $(function () {
        $('.photo-list img').on('click', function () {
            layer.photos({
                photos: '.photo-list',
                shadeClose: false,
                closeBtn: 2,
                anim: 5
            });
        })
    });
</script>
{/block}

